{% if page.url == "/" %}<output>
<h2 id="download">{{ site.locales[lang].download }}</h2>
<div><span class="spinning"></span></div>
<table class="table-downloads">
<thead>
<tr>
<th>{{ site.locales[lang].relnotes }}</th>
<th>{{ site.locales[lang].download }}</th>
<th>{{ site.locales[lang].date }}</th>
</tr>
</thead>
<tbody></tbody>
</table>
<div class="loading"><center><a href="{{ site.github.releases_url }}" title="Releases">Releases on GitHub</a></center></div>
<script>
$.getJSON("{{ site.github.api_url }}/repos/{{ site.github.repository_nwo }}/releases").done(function(json){
for(var i=0;i<json.length && i<3;i++){
var release=json[i];if(release.assets.length===0) continue;
for(var j=0;j<release.assets.length;j++){
var asset=release.assets[j];var fileSize=Math.round(asset.size/1024);
$(".table-downloads tbody").append($("<tr>")
.append($("<td>").append($("<a>").attr("href",release.html_url).text(release.name)).append(release.prerelease?" ~":""))
.append($("<td>").append(asset.name+" ").append($("<a>").attr("href",asset.browser_download_url).text(fileSize.toLocaleString()+"KB")))
.append($("<td>").text(asset.updated_at.substring(0,10))));
}}
$(".spinning").hide();
$(".table.downloads").fadeIn();
});
</script>
</output>{% endif %}
